
/**
 * Demonstrates a range of Button options the framework offers out of the box
 */
Ext.define('cloud.view.role.RoleEdit', {
    extend: 'Ext.form.Panel',
    xtype: 'roleEdit',
    requires: [
        'Ext.form.Panel',
        'Ext.form.FieldSet',
        'Ext.field.Select',
        'Ext.Img'
    ],
    editor: false,
    config: {
        title:'编辑角色',
        items:[
            {
                xtype: 'toolbar',
                docked: 'bottom',
                layout: {
                    type: 'hbox',
                    pack: 'end'
                },
                items: [
                    {
                        id: 'role_edit',
                        iconMask: true,
                        cls:'x-button2',
                        scope: this,
                        text: '提交',
                        style: 'float:right'
                    }
                ]
            },
            {
                xtype:'fieldset',
                title:'添加角色',
                items: [
                    {
                        xtype:'textfield',
                        label:'应用ID',
                        name:'caid',
                        readOnly:true,
                        hidden:true
                    },
                    {
                        xtype:'textfield',
                        label:'角色ID',
                        id:'role_id_edit',
                        readOnly:true,
                        hidden:true
                    },
                    {
                        xtype:'textfield',
                        label:'角色名称',
                        name:'name',
                        id:'role_name_edit'
                    },
                    {
                        xtype: 'togglefield',
                        name: 'status',
                        id: 'role_status_add',
                        label: '是否启用',
                        value: '1'
                    }
                ]
            }
        ]
    }
});